package com.hejielife.producerconsumer6;

/**
 * 2019年8月2日 下午2:03:39
 * 
 * @author hejielife
 * @despribe Something like sleep();
 */
public class Something {
	public static void method(long x) throws InterruptedException {
		if (x != 0) {
			Object object = new Object();
			synchronized (object) {
				object.wait(x);
			}
		}
	}

	public static void main(String[] args) throws InterruptedException {
		System.out.println("start");
		Something.method(1000);
		System.out.println("end");
	}
}
